<html>
<head>
	<meta charset="utf-8">
	<title></title>
	<script type="text/javascript">
	// var goods=new Object();
	// goods.name="西瓜";
	// goods.num=20;
	// document.write(goods["name","num"]);
	// goods.input=dome;
	// goods.input();
	// function dome(){
	// 	alert(goods.name);
	// }

	// var user = {};
	// document.write(typeof user);

	// var box={
	// 	name:"xiaohei",
	// 	age:1
	// };
	// for(attr in box){
	// 	document.write(box[attr]);
	// }


	function People(name,age,sex){
		this.name=name;
		this.age=age;
		this.sex=sex;
	}
	var xiaohong=new People();
	 for(attr in xiaohong){
		document.write(attr+",");
	}
	document.write(xiaohong.name);

	// document.write(attr);
	// var xiaohei=new People("xiaohei",18,"男");
	// var xiaobai=new People("xiaobai",19,"男");
	// document.write(xiaohei.name+","+xiaobai.name);
	</script>
</head>
<body>

</body>
</html>